package com.shop.milk_tea_shop.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * <p>
 * 
 * </p>
 *
 * @author yjw
 * @since 2024-06-16
 */
@TableName("order_detail_table")
@ApiModel(value = "OrderDetail对象", description = "")
public class OrderDetail implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("订单id（T/W+店铺id+日期+取餐号）")
    @TableId("order_id")
    private String orderId;

    @ApiModelProperty("用户id")
    private Long userId;

    @ApiModelProperty("店铺id")
    private Long shopId;

    @ApiModelProperty("取餐号")
    private String pickupNumber;

    @ApiModelProperty("订单中商品信息")
    private String items;

    @ApiModelProperty("订单总价")
    private Double total;

    @ApiModelProperty("订单状态，0：退款，1：制作中，2：待取餐，3：已取餐")
    private Integer status;

    @ApiModelProperty("创建时间")
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createTime;

    @ApiModelProperty("修改时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime alterTime;

    @ApiModelProperty("扩展字段")
    private String extra;

    public String getOrderId() {
        return orderId;
    }

    public void setOrderId(String orderId) {
        this.orderId = orderId;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public String getPickupNumber() {
        return pickupNumber;
    }

    public void setPickupNumber(String pickupNumber) {
        this.pickupNumber = pickupNumber;
    }

    public String getItems() {
        return items;
    }

    public void setItems(String items) {
        this.items = items;
    }

    public Double getTotal() {
        return total;
    }

    public void setTotal(Double total) {
        this.total = total;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public LocalDateTime getCreateTime() {
        return createTime;
    }

    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }

    public LocalDateTime getAlterTime() {
        return alterTime;
    }

    public void setAlterTime(LocalDateTime alterTime) {
        this.alterTime = alterTime;
    }

    public Long getShopId() {
        return shopId;
    }

    public void setShopId(Long shopId) {
        this.shopId = shopId;
    }

    public String getExtra() {
        return extra;
    }

    public void setExtra(String extra) {
        this.extra = extra;
    }

    @Override
    public String toString() {
        return "OrderDetail{" +
                "orderId='" + orderId + '\'' +
                ", userId=" + userId +
                ", shopId=" + shopId +
                ", pickupNumber='" + pickupNumber + '\'' +
                ", items='" + items + '\'' +
                ", total=" + total +
                ", status=" + status +
                ", createTime=" + createTime +
                ", alterTime=" + alterTime +
                ", extra='" + extra + '\'' +
                '}';
    }
}
